<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <script src="./lib/vue-2.4.0.js"></script>
    <style>
        .outer{
            height: 120px;
            width:120px;
            margin: 0 auto;
            background-color: darkcyan;
        }
    </style>
</head>
<body>
    <div id="app">
        <div class="outer" @click="o">
            <button @click.stop="btn">123</button>
        </div>
        <a href="http://www.baidu.com" @click.prevent="link">去百度</a>
    </div>
    <script>
        var vm = new Vue({
            el:'#app',
            data:{},
            methods:{
                btn(){
                    alert("btn")
                },
                o:function(){
                    alert("outer")
                },
                link(){
                    console.log("触发了连接的点击事件")
                }
            }
        })
    </script>
</body>
</html>